#include<iostream>
#include<algorithm>
#include<cstdlib>
#include<cstring>
#include<cstdio>
#include<string>
#include<cmath>
#include<set>
#include<map>
using namespace std;
long long fibonacci(long long a);
int main()
{
	long long n,a;
	cin>>n;
	while(n--)
	{
		cin>>a;
		cout<<fibonacci(a)<<endl;
	}
    return 0;
}
long long fibonacci(long long a)
{
	if(a==1||a==2)
		return 1;
	return fibonacci(a-1)+fibonacci(a-2);
}
